![Collapse image](collapse_all.gif)
![Expand Image](expand_all.gif)
![](collapse_all.gif)
![](expand_all.gif)
![](dropdown.gif)
![](dropdownHover.gif)
![Copy image](copycode.gif)
![CopyHover image](copycodeHighlight.gif)
![]() ![]() |
.NET Framework Class Library |
ParallelEnumerable..::.Union<(Of <(TSource>)>) Method (ParallelQuery<(Of <(TSource>)>), ParallelQuery<(Of <(TSource>)>)) |
ParallelEnumerable Class See Also Send Feedback |
Produces the set union of two parallel sequences by using the default equality comparer.
Namespace:
System.Linq
Assembly:
System.Threading (in System.Threading.dll)
Syntax
Visual Basic (Declaration) |
---|
Public Shared Function Union(Of TSource) ( _ first As ParallelQuery(Of TSource), _ second As ParallelQuery(Of TSource) _ ) As ParallelQuery(Of TSource) |
C# |
---|
public static ParallelQuery<TSource> Union<TSource>( ParallelQuery<TSource> first, ParallelQuery<TSource> second ) |
Parameters
- first
- Type: System.Linq..::.ParallelQuery<(Of <(TSource>)>)
A sequence whose distinct elements form the first set for the union.
- second
- Type: System.Linq..::.ParallelQuery<(Of <(TSource>)>)
A sequence whose distinct elements form the second set for the union.
Type Parameters
- TSource
- The type of the elements of the input sequences.
Return Value
A sequence that contains the elements from both input sequences, excluding duplicates.
Exceptions
Exception | Condition |
---|---|
System..::.ArgumentNullException | first or second is a null reference (Nothing in Visual Basic). |